package com.cloud.demo.models.sys.service.impl;

import com.cloud.demo.models.sys.domain.SysRole;
import com.cloud.demo.models.sys.mapper.SysRoleMapper;
import com.cloud.demo.models.sys.qo.SysRoleQuery;
import com.cloud.demo.models.sys.service.SysRoleService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

/**
* 用户服务接口实现
*/
@Service
@Transactional
public class SysRoleServiceImpl extends ServiceImpl<SysRoleMapper,SysRole> implements SysRoleService  {

    @Override
    public IPage<SysRole> queryPage(SysRoleQuery qo) {
        IPage<SysRole> page = new Page<SysRole>(qo.getCurrentPage(), qo.getLimit());
        QueryWrapper<SysRole> wrapper = Wrappers.<SysRole>query();
        return super.page(page, wrapper);
    }
}
